<!DOCTYPE html>
<html lang="en">

<head>
 <meta charset="UTF-8">
 <meta name="viewport"
  content="width=device-width, initial-scale=1.0, minimum-scale=1,maximum-scale=1,user-scalable=no">
 <meta http-equiv="X-UA-Compatible" content="ie=edge">
 <title data-ch="恐龙探险" data-en="Dinosaur Adventure" class="document_title">恐龙探险</title>
 <script src="js/jquery-3.3.1.min.js"></script>
 <script src="js/common.js"></script>
 <script src="js/rem.js"></script>
 <script src="js/layer.js"></script>
 <script type="text/javascript">
  isLogin();
 </script>
 <link rel="stylesheet" href="css/common.css">
 <link rel="stylesheet" href="css/index.css">
</head>

<body>
 <!--头部-->
 <div class=" jui_top_bar">
  <a class="jui_top_left" href="javascript:history.back(-1)"><img src="icons/back.png"></a>
  <div class="jui_top_middle font_weight" data-ch="最新资讯" data-en="Latest news">最新资讯</div>
 </div>
 <!-- 头部end -->
 <!-- 内容部分 -->
 <div class="shouyi_list_box jui_main">
  <!-- 列表部分 -->

  <!-- 内容为空时显示 -->
  <div class="if_null">
   <img class="if_null_img" src="./icons/nothing.png" alt="">
   <div class="if_null_text col_000 f30" data-ch="暂无内容" data-en="No data">暂无内容</div>
  </div>
 </div>

 <script>
  $(function(){
   var data = {
    uid: localStorage.getItem("u_id"),
    token: localStorage.getItem("token"),
    language_type: localStorage.getItem("language_type"),
   }
   $.ajax({
    type: 'post',
    url: baseURL + '/index.php?m=index&c=mess_list',
    data: data,
    success: function success(data){
     data = JSON.parse(data);
	 is_login(data);
     if(data.code == 1){
      var newList = '';
      if(data.data.length == 0){
       newList = `<div class="if_null">
         <img class="if_null_img" src="./icons/nothing.png" alt="">
         <div class="if_null_text col_000 f30" data-ch="暂无内容" data-en="No data">暂无内容</div>
        </div>`
      } else {
       data.data.forEach(function(item){
        let time = item.create_time.split(" ")[0]
        newList += `<div class="shouyi_list border_radius02 latout_mask">
          <div class="shouyi_list_top flex_be">
           <div class="col_fff news_list_title f32" style="text-align:left">${item.title}</div>
           <div class="col_fff news_list_time f28">${time}</div>
          </div>
          <div class="shouyi_list_bottom news_list_details col_fff f328">${item.content}
          </div>
         </div>`
       })
      }
      $(".shouyi_list_box").html(newList);
      
     }
    }
   })
  })
  language();
  documentName()
 </script>
</body>

</html>